package com.cxso.example.domain.wlpt.goods;

import com.cxso.example.enums.wlpt.CustomPayeeEnum;
import com.cxso.example.enums.wlpt.DetailMethodEnum;
import com.cxso.example.enums.wlpt.FeeTypeEnum;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;

import javax.validation.constraints.DecimalMin;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Positive;
import java.math.BigDecimal;

@Setter
@Getter
@Accessors(chain = true)
@Schema(description = "费用项信息")
public class ApiGoodsFeeItemDomain {

    @Schema(description = "费用id")
    private String id;

    @Schema(description = "费用类型")
    @NotNull(message = "费用类型不能为空！")
    private FeeTypeEnum feeType;

    @Schema(description = "自定义费用名称")
    private String customName;

    @Schema(description = "自定义单价")
    @NotNull(message = "自定义单价不能为空！")
    @DecimalMin(value = "0", message = "自定义单价不能小于0")
    private BigDecimal customUnit;

    @Schema(description = "自定义费用计价方式")
    private DetailMethodEnum customMethod;

    @Schema(description = "自定义费用总额")
    private BigDecimal detailTotalAmount;

    @Schema(description = "增补金额")
    @Positive(message = "增补金额必需要大于0")
    private BigDecimal augmentAmount;

    @Schema(description = "扣减金额")
    @Positive(message = "扣减金额必需要大于0")
    private BigDecimal deductionAmount;

    @Schema(description = "增补扣减原因")
    private String augmentDeductionReason;

    @Schema(description = "自定义费用收款方")
    private CustomPayeeEnum customPayee;

    @Schema(description = "自定义费用收款人,如果类型为司机收款此处不接收入参")
    private String customPayeeId;

    @Schema(description = "自定义费用收款人名称")
    private String payeeName;

    @Schema(description = "自定义费用收款人银行卡ID")
    private String customPayeeBankCardId;

    @Schema(description = "自定义费用收款人银行卡号")
    private String payeeBankCard;

}
